<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@page import="model.Category,model.CategoryItem,java.util.Iterator,model.Figure,model.Color" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
    <head>
       <meta charset="UTF-8">
        <title>Мода от индия</title>
		<link rel="stylesheet" href="css/typography.css" type="text/css" charset="utf-8">
        <link rel="stylesheet" href="css/product.css" type="text/css" charset="utf-8">
    </head>
<body>
 <div class="page">
 <div class="header">
     <h1>Мода от Индия</h1>
 </div>

<div class="main">
<div class="content">
<div class="inner">
<ul class="products">
	<%
		Category category = (Category)request.getAttribute("category");
			Iterator<CategoryItem> items = category.getClothingItems();
			while(items.hasNext()){	
		CategoryItem item = items.next();
		Iterator<Figure> figures = item.getFigures();
		while(figures.hasNext()){
			Figure figure = figures.next();
			Iterator<Color> colors = item.getColors();
	%>
			<li>
                  <div class="img-holder"><a href=""><img class="product-cover" src="<%=figure.getPath()%>" alt="снимка на продукт"></a></div>
                  <div class="text-holder">
                      <h5><strong><a href=""><%= item.getDescription()%></a></strong></h5>
                      <span class="price"><%=item.getPrice()%> лв</span>
                      <div class="color-boxes">
                         <%while(colors.hasNext()) {  %>
                         	<span class="color" style="background-color:<%=colors.next().getCode() %>"></span>
                        <% 
                         	}
                        %>
                          
                          
                      </div>
                      <a href="" class="more" title="">Още...</a>
                  </div>
             </li>
	
	 <%	
			}
		}
	 %>
</ul>
</div>

</div>
<div class="sidebar">
</div>
</div>
</div>
 <div class="footer">
</div>

</body>
</html>